Automatic exposure control involves generating an appropriate amount of light from a camera flash based on ambient illumination and possibly autofocus (AF) distance information. Some systems have real-time hardware feedback such that a flash pulse is terminated when enough light is reflected back from a target scene.